Skip to content

Add equality on Rows/Row/Field#85

Merged
SeanTAllen merged 1 commit intomainfrom
sean/add-equality-on-rows-row-field
Feb 11, 2026
Merged

Add equality on Rows/Row/Field#85
SeanTAllen merged 1 commit intomainfrom
sean/add-equality-on-rows-row-field

Conversation

@SeanTAllen
Copy link
Copy Markdown
Member

Implement Equatable on Field, Row, and Rows val classes, enabling ==/!= comparisons.

  • Field.eq compares name and value, matching on all 8 FieldDataTypes variants
  • Row.eq does element-wise field comparison
  • Rows.eq does element-wise row comparison
  • 8 new unit tests covering reflexive, structural, and symmetric equality plus inequality
  • Removes the TODO in rows.pony that requested this feature

Item #33 from the roadmap (discussion #72).

@SeanTAllen SeanTAllen added the changelog - added Automatically add "Added" CHANGELOG entry on merge label Feb 11, 2026
@ponylang-main ponylang-main added the discuss during sync Should be discussed during an upcoming sync label Feb 11, 2026
@SeanTAllen SeanTAllen removed the changelog - added Automatically add "Added" CHANGELOG entry on merge label Feb 11, 2026
@SeanTAllen SeanTAllen force-pushed the sean/add-equality-on-rows-row-field branch from 77d23da to c19aeb7 Compare February 11, 2026 16:07
Implement Equatable on Field, Row, and Rows val classes to enable ==
and != comparisons. Field.eq compares name and value, matching on all 8
FieldDataTypes variants. Row.eq and Rows.eq do ordered element-wise
comparison — field/row order matters.

Tests include both example-based tests (reflexive, structural,
symmetric equality plus targeted inequality cases) and PonyCheck
property tests that verify invariants across randomly generated values.

This was item #33 in the project roadmap (discussion #72) and removes
the TODO that was in rows.pony requesting this feature.
@SeanTAllen SeanTAllen force-pushed the sean/add-equality-on-rows-row-field branch from 3877425 to 7b9f27f Compare February 11, 2026 17:31
@SeanTAllen SeanTAllen merged commit 6d1dd66 into main Feb 11, 2026
8 checks passed
@SeanTAllen SeanTAllen deleted the sean/add-equality-on-rows-row-field branch February 11, 2026 17:40
@ponylang-main ponylang-main removed the discuss during sync Should be discussed during an upcoming sync label Feb 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants